# Maintainer: SANO Masatoshi <snmsts@gmail.com>
_realname=roswell
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=22.12.14.113
pkgrel=1
pkgdesc="Lisp installer and launcher (mingw-w64)"
url="https://github.com/roswell/roswell"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32')
license=("MIT")
depends=()
makedepends=("${MINGW_PACKAGE_PREFIX}-autotools"
             "${MINGW_PACKAGE_PREFIX}-cc")
optdepends=()
source=("https://github.com/roswell/roswell/archive/v$pkgver.tar.gz")
sha256sums=('eb7e538e82822f857360d040b755e03ad2fdf87f151d34dafdae2a1180e7ec0b')

build() {
  cd "${srcdir}"/${_realname}-${pkgver}
  ./bootstrap
  ./configure \
    --prefix=${MINGW_PREFIX} \
    --build=${MINGW_CHOST} \
    --host=${MINGW_CHOST} \
    --target=${MINGW_CHOST} \

  make
}

package() {
  cd "${_realname}-$pkgver"

  make install DESTDIR="${pkgdir}"

  install -Dm644 COPYING "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE"

}
